#Region "File Description"
'-----------------------------------------------------------------------------
' OptionsMenuScreen.cs
'
' Microsoft XNA Community Game Platform
' Copyright (C) Microsoft Corporation. All rights reserved.
'-----------------------------------------------------------------------------
#End Region

#Region "Using Statements"
Imports Microsoft.Xna.Framework
#End Region

''' <summary>
''' The options screen is brought up over the top of the main menu
''' screen, and gives the user a chance to configure the game
''' in various hopefully useful ways.
''' </summary>
Class OptionsMenuScreen
	Inherits MenuScreen
	#Region "Fields"

	'MenuEntry ungulateMenuEntry;
	Private languageMenuEntry As MenuEntry
	'MenuEntry frobnicateMenuEntry;
	'MenuEntry elfMenuEntry;

	'enum Ungulate
	'{
	'    BactrianCamel,
	'    Dromedary,
	'    Llama,
	'}

	'static Ungulate currentUngulate = Ungulate.Dromedary;

	Shared languages As String() = {"Italian", "English"}
	Shared currentLanguage As Integer = 1

	Shared frobnicate As Boolean = True

	'static int elf = 23;

	#End Region

	#Region "Initialization"


	''' <summary>
	''' Constructor.
	''' </summary>
	Public Sub New()
		MyBase.New("Options")
		' Create our menu entries.
		languageMenuEntry = New MenuEntry(String.Empty)

		SetMenuEntryText()

		Dim back As New MenuEntry("Back")

		' Hook up menu event handlers.
		AddHandler languageMenuEntry.Selected, AddressOf LanguageMenuEntrySelected
		AddHandler back.Selected, AddressOf OnCancel

		' Add entries to the menu.
		MenuEntries.Add(languageMenuEntry)
		MenuEntries.Add(back)
	End Sub


	''' <summary>
	''' Fills in the latest values for the options screen menu text.
	''' </summary>
	Private Sub SetMenuEntryText()
		languageMenuEntry.Text = "Language: " & languages(currentLanguage)
	End Sub


	#End Region

	#Region "Handle Input"


	''' <summary>
	''' Event handler for when the Language menu entry is selected.
	''' </summary>
	Private Sub LanguageMenuEntrySelected(sender As Object, e As PlayerIndexEventArgs)
		currentLanguage = (currentLanguage + 1) Mod languages.Length

		SetMenuEntryText()
	End Sub



	#End Region
End Class
